﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeBehind="TeamPlayersDetails.aspx.cs" 
Inherits="Nivdal.TeamPlayersDetails" Theme="SkinFile" StylesheetTheme="SkinFile" %>

<%@ Register Assembly="obout_Flyout2_NET" Namespace="OboutInc.Flyout2" TagPrefix="cc1" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadPlaceHolder" runat="server">
    <script language="javascript" type="text/javascript">

        $(function () {
            $("#ctl00_ctl00_ContentPlaceHolder3_ContentPlaceHolder1_PlayersGridView").tablesorter(
            //                { cssHeader: "NheaderNoSort" },
            //                { cssAsc: "NheaderSortUp" },
            //                { cssDesc: "NheaderSortDown" }
            );
        })
        

    </script>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="PageNamePlaceHolder" runat="server">
    <asp:Label ID="PageNameLabel" runat="server" Text="<%$ Resources:Resource, TeamListOfPlayers_PageNameLabel %>"  CssClass="PageNameContentStyle"></asp:Label>
    <asp:HyperLink ID="TeamHyperLink" runat="server" Text="<%$ Resources:Resource, Global_Team %>"  CssClass="PageNameContentStyle"></asp:HyperLink>
    <asp:Label ID="PostTeamNameLabel" runat="server" Text="<%$ Resources:Resource, TeamListOfPlayers_PostTeamNameLabel %>"  CssClass="PageNameContentStyle"></asp:Label>
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="basic_element">
    <div class="red_title">
        <asp:Label ID="NumberOfPlayersLabel" runat="server" CssClass="white_title"></asp:Label>
    </div>
    <div class="padding5">
        <asp:GridView ID="PlayersGridView" runat="server" SkinID="SimpleProfessional" DataSourceID="TeamListOfPlayersSqlDataSource" AllowPaging="false"
         AutoGenerateColumns="false" CellPadding="1"  UseAccessibleHeader="true">
         <Columns>
            <asp:TemplateField ItemStyle-Width="33%" HeaderText="<%$ Resources:Resource, Global_Player %>">
                <HeaderStyle CssClass="CursorPointer" />
            
                <ItemTemplate>
                    <asp:Label ID="PlayersSortLabel" runat="server" Text='<%# Eval("ShirtNumber") + " " + Eval("Name") %>' style="display:none;" ></asp:Label>
                    <asp:HiddenField ID="PlayerIdHiddenField" runat="server" Value='<%# Eval("Id") %>' />
                    <%--<asp:CheckBox ID="CompareCheckBox" runat="server" ToolTip="<%$ Resources:Resource, Global_CheckForCompare %>" />--%>
                    <asp:ImageButton ID="FlagImageButton" runat="server" ImageUrl='<%# Eval("Flag", "~/Images/Flags/{0}") %>'
                     ToolTip='<%# Eval("CountryName") %>' PostBackUrl='<%# Eval("Nationality", "Country.aspx?Id={0}") %>' />
                     &nbsp;
                    <asp:Label ID="ShirtNumLabel" runat="server" Text='<%# Eval("ShirtNumber") %>' SkinID="GridLabel"></asp:Label>
                    <asp:HyperLink ID="PlayerHyperlink" runat="server" ToolTip='<%# Eval("Name") %>'
                        NavigateUrl='<%# "~/Player.aspx?Id=" + Eval("Id") %>' Text='<%# Eval("ShortName") %>' SkinID="GreenTitleHyperLink"></asp:HyperLink>
                    &nbsp;                
                
                    <asp:Image ID="YellowCard1Image" runat="server" ImageUrl="~/Images/Icons/players_yellow.jpg" 
                    Visible='<%# Eval("OneYellowVisible") %>' ToolTip='<%# Eval("WarningsToolTip") %>' />
                    <asp:Image ID="YellowCard2Image" runat="server" ImageUrl="~/Images/Icons/players_yellow.jpg" 
                    Visible='<%# Eval("SecondYellowVisible") %>' ToolTip='<%# Eval("WarningsToolTip") %>' />
                    <asp:Image ID="RedCardImage" runat="server" ImageUrl="~/Images/Icons/players_red.jpg" 
                    Visible='<%# Eval("RedVisible") %>' ToolTip='<%# Eval("WarningsToolTip") %>' />
                    <asp:Image ID="InjuryImage" runat="server" ImageUrl='<%# InjuryIconName(Eval("InjuryRowData")) %>' 
                     ToolTip='<%# Eval("Injury") %>' Visible='<%# Eval("IsInjured") %>' /> 
                    <asp:Image ID="ForSaleImage" runat="server" ImageUrl="~/Images/Icons/atuk.png" 
                    ToolTip="<%$ Resources:Resource, ListOfplayers_ForSaleToolTip %>" Visible='<%# Eval("IsForSale") %>' />
                
                    <asp:Image ID="PrivateNoteImage" runat="server" ImageUrl="~/Images/Icons/PrivateNote.png" Visible='<%# PrivateNoteVisible(Eval("PrivateNote")) %>' />
                    <cc1:Flyout ID="PrivateNoteFlyout" runat="server" AttachTo="PrivateNoteImage" Position="TOP_CENTER" 
                    Visible='<%# PrivateNoteVisible(Eval("PrivateNote")) %>' NoneEffect="True">
                        <div class="ToolTipStyle">
                            <asp:Label ID="PrivateNoteLabel" runat="server" Text='<%# Eval("PrivateNote").ToString().Replace("\r\n", " <br />") %>'></asp:Label>
                        </div>
                    </cc1:Flyout>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderTemplate>
                    <asp:Label ID="FitnessHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_AgeAbbreviation %>"
                    ToolTip="<%$ Resources:Resource, Global_Age %>"></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <div style="display:none;"><%# Eval("AgeSort") %></div>
                    <asp:Label ID="AgeLabel" runat="server" Text='<%# Eval("Age") %>' SkinID="GridLabel" ToolTip='<%# Eval("AgeTollTip") %>' />
                </ItemTemplate>        
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="FitnessHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_FitnessHeader %>"  ToolTip="<%$ Resources:Resource, Global_Fitness %>"
                    SkinID="GridLikeLinkButton" OnClick="SortByFitness"></asp:LinkButton>--%>
                    <asp:Label ID="FitnessHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_FitnessHeader %>"
                    ToolTip="<%$ Resources:Resource, Global_Fitness %>"></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="FitnessLabel" runat="server" Text='<%# Eval("Fitness") %>' 
                    SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Fitness %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="CharismaHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_CharismaTitleLabel %>"  ToolTip="<%$ Resources:Resource, Global_Charisma %>"
                    SkinID="GridLikeLinkButton" OnClick="SortByCharisma"></asp:LinkButton>--%>
                    <asp:Label ID="CharismaHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_CharismaTitleLabel %>"  
                    ToolTip="<%$ Resources:Resource, Global_Charisma %>"></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="CharismaLabel" runat="server" Text='<%# Eval("Charisma") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Charisma %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="ExperienceHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_ExperienceHeader %>"  ToolTip="<%$ Resources:Resource, Global_Experience%>"
                    SkinID="GridLikeLinkButton" OnClick="SortByExperience"></asp:LinkButton>--%>
                    <asp:Label ID="ExperienceHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_ExperienceHeader %>"  
                    ToolTip="<%$ Resources:Resource, Global_Experience%>"></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="ExperienceLabel" runat="server" Text='<%# Eval("Experience") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Experience %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="3%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="StrongFootHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_StrongFootHeader%>"  ToolTip="<%$ Resources:Resource, Global_StrongFoot %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByStrongFoot"></asp:LinkButton>--%>
                    <asp:Label ID="StrongFootHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_StrongFootHeader%>"  
                    ToolTip="<%$ Resources:Resource, Global_StrongFoot %>" ></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="StrongFootLabel" runat="server" Text='<%# Eval("StrongFootShort") %>' SkinID="GridLabel" 
                    ToolTip='<%# Resources.Resource.Global_StrongFoot + ": " + Eval("StrongFoot") %>' />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="InstinctsHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_InstinctsHeader %>"  ToolTip="<%$ Resources:Resource, Global_Instincts %>"
                    SkinID="GridLikeLinkButton" OnClick="SortByInstincts"></asp:LinkButton>--%>
                    <asp:Label ID="InstinctsHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_InstinctsHeader %>"  
                    ToolTip="<%$ Resources:Resource, Global_Instincts %>"></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="InstinctsLabel" runat="server" Text='<%# Eval("Instincts") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Instincts %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="GoalKeepingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_GoalKeepingHeader %>"  ToolTip="<%$ Resources:Resource, Global_GoalKeeping %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByGoalKeeping"></asp:LinkButton>--%>
                    <asp:Label ID="GoalKeepingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_GoalKeepingHeader %>"  
                    ToolTip="<%$ Resources:Resource, Global_GoalKeeping %>" ></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="GoalKeepingLabel" runat="server" Text='<%# Eval("GoalKeeping") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_GoalKeeping %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="PositioningHeaderLabel" runat="server"  Text="<%$ Resources:Resource, TeamListOfPlayers_PositioningHeaderLabel %>" ToolTip="<%$ Resources:Resource, Global_Positioning %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByPositioning"></asp:LinkButton>--%>
                    <asp:Label ID="PositioningHeaderLabel" runat="server" Text="<%$ Resources:Resource, TeamListOfPlayers_PositioningHeaderLabel %>" 
                    ToolTip="<%$ Resources:Resource, Global_Positioning %>" ></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="PositioningLabel" runat="server" Text='<%# Eval("Positioning") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Positioning %>" />
                </ItemTemplate>
            </asp:TemplateField>                
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="StaminaHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_StaminaHeader %>" ToolTip="<%$ Resources:Resource, Global_Stamina %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByStamina"></asp:LinkButton>--%>
                    <asp:Label ID="StaminaHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_StaminaHeader %>"
                    ToolTip="<%$ Resources:Resource, Global_Stamina %>"></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="StaminaLabel" runat="server" Text='<%# Eval("Stamina") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Stamina %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="PowerHeaderLabel" runat="server" Text="<%$ Resources:Resource, TeamListOfPlayers_PowerHeaderLabel %>" ToolTip="<%$ Resources:Resource, Global_Power %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByPower"></asp:LinkButton>--%>
                    <asp:Label ID="PowerHeaderLabel" runat="server"  Text="<%$ Resources:Resource, TeamListOfPlayers_PowerHeaderLabel %>" 
                    ToolTip="<%$ Resources:Resource, Global_Power %>" ></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="PowerLabel" runat="server" Text='<%# Eval("Power") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Power %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="TacklingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_TacklingHeader %>" ToolTip="<%$ Resources:Resource, Global_Tackling %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByTackling"></asp:LinkButton>--%>
                    <asp:Label ID="TacklingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_TacklingHeader %>" 
                    ToolTip="<%$ Resources:Resource, Global_Tackling %>" ></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="TacklingLabel" runat="server" Text='<%# Eval("Tackling") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Tackling %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="HeadingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_HeadersTitleAbbreviation %>"  ToolTip="<%$ Resources:Resource, Global_Heading %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByHeading"></asp:LinkButton>--%>
                    <asp:Label ID="HeadingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_HeadersTitleAbbreviation %>"  
                    ToolTip="<%$ Resources:Resource, Global_Heading %>" ></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="HeadingLabel" runat="server" Text='<%# Eval("Heading") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Heading %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate> 
                    <%--<asp:LinkButton ID="QuicknessHeaderLabel" runat="server" Text="<%$ Resources:Resource, TeamListOfPlayers_QuicknessHeaderLabel %>"  ToolTip="<%$ Resources:Resource, Global_Quickness %>"
                    SkinID="GridLikeLinkButton" OnClick="SortByQuickness"></asp:LinkButton>--%>
                    <asp:Label ID="QuicknessHeaderLabel" runat="server" Text="<%$ Resources:Resource, TeamListOfPlayers_QuicknessHeaderLabel %>"  
                    ToolTip="<%$ Resources:Resource, Global_Quickness %>"></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="QuicknessLabel" runat="server" Text='<%# Eval("Quickness") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Quickness %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="TechniqueHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_TechniqueHeader %>" ToolTip="<%$ Resources:Resource, Global_Technique %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByTechnique"></asp:LinkButton>--%>
                    <asp:Label ID="TechniqueHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_TechniqueHeader %>" 
                    ToolTip="<%$ Resources:Resource, Global_Technique %>" ></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="TechniqueLabel" runat="server" Text='<%# Eval("Technique") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Technique %>"  />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="ShortPassingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_ShortPassingHeader %>" ToolTip="<%$ Resources:Resource, Global_ShortPassing %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByShortPassing"></asp:LinkButton>--%>
                    <asp:Label ID="ShortPassingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_ShortPassingHeader %>" 
                    ToolTip="<%$ Resources:Resource, Global_ShortPassing %>" ></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="ShortPassingLabel" runat="server" Text='<%# Eval("ShortPassing") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_ShortPassing %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="LongPassingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_LongPassingHeader %>"  ToolTip="<%$ Resources:Resource, Global_LongPassing %>"
                    SkinID="GridLikeLinkButton" OnClick="SortByLongPassing"></asp:LinkButton>--%>
                    <asp:Label ID="LongPassingHeaderLabel" runat="server" Text="<%$ Resources:Resource, Global_LongPassingHeader %>"  
                    ToolTip="<%$ Resources:Resource, Global_LongPassing %>"></asp:Label>
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="LongPassingLabel" runat="server" Text='<%# Eval("LongPassing") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_LongPassing %>" />
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField ItemStyle-Width="4%">
                <HeaderStyle CssClass="CursorPointer" />
                <HeaderTemplate>
                    <%--<asp:LinkButton ID="ShootingHeaderLabel" runat="server" Text="<%$ Resources:Resource, TeamListOfPlayers_ShootingLabel %>"  ToolTip="<%$ Resources:Resource, Global_Shooting %>" 
                    SkinID="GridLikeLinkButton" OnClick="SortByShooting"></asp:LinkButton>--%>      
                    <asp:Label ID="Label1" runat="server"  Text="<%$ Resources:Resource, TeamListOfPlayers_ShootingLabel %>"  
                    ToolTip="<%$ Resources:Resource, Global_Shooting %>" ></asp:Label>      
                </HeaderTemplate>
                <ItemTemplate>
                    <asp:Label ID="ShootingHeaderLabel" runat="server" Text='<%# Eval("Shooting") %>' SkinID="GridLabel" ToolTip="<%$ Resources:Resource, Global_Shooting %>" />
                </ItemTemplate>
            </asp:TemplateField>
         </Columns>
         <EmptyDataTemplate>
            <asp:Label ID="NoPlayersLabel" runat="server" Text="<%$ Resources:Resource, TeamListOfPlayers_NoPlayersText %>" SkinID="GridLabel"></asp:Label>
        </EmptyDataTemplate>
        </asp:GridView>

        <asp:SqlDataSource ID="TeamListOfPlayersSqlDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
            SelectCommand="Nivdal_GetListOfPlayersForTeam" SelectCommandType="StoredProcedure">
        </asp:SqlDataSource>
    </div>
    </div>
    
    
</asp:Content>
